package com.finance.cooperate.data;

import com.finance.cooperate.data.listener.InitListener;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.web.servlet.ServletListenerRegistrationBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.EnableAspectJAutoProxy;


/**
 * @ClassName CooperateDataApplication
 * @Description 数据生成
 * @Author shen
 * @Date 2023/8/10 18:02
 * @Modify ...
 */
@Configuration
@SpringBootApplication(scanBasePackages = "com.finance.cooperate")
@EnableAspectJAutoProxy(exposeProxy = true)
@SuppressWarnings("all")
public class CooperateDataApplication {


    public static void main(String[] args){
        SpringApplication.run(CooperateDataApplication.class, args);
    }


    /**
     * @Author shen
     * @Description 注册监听器
     * @Date 5:15 下午 2020/6/10
     * @Param []
     * @return org.springframework.boot.web.servlet.ServletListenerRegistrationBean
     **/
    @Bean
    public ServletListenerRegistrationBean servletListenerRegistrationBean() {
        ServletListenerRegistrationBean servletListenerRegistrationBean = new ServletListenerRegistrationBean();
        servletListenerRegistrationBean.setListener(new InitListener());
        return servletListenerRegistrationBean;
    }



}
